<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateActivitiesTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('activities', function (Blueprint $table) {
            $table->increments('id');
            $table->smallInteger('industries_id');
            $table->smallInteger('media_id');
            $table->smallInteger('templates_id');
            $table->integer('advertis_id');
            $table->string('name');
            $table->tinyInteger('count');
            $table->string('background_url', 70);
            $table->string('subject_url', 70);
            $table->string('banner_bg', 70);
            $table->string('banner_font', 70);
            $table->string('explain_url', 70);
            $table->string('close_url', 70);
            $table->string('lamplight_url', 70);
            $table->string('title_bg', 7);
            $table->text('explain');
            $table->string('winning_list', 300);
            $table->enum('switch', ['1', '2'])->default('1');
            $table->softDeletes();
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('activities');
    }
}
